<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<title>专题管理</title>
<meta http-equiv="Content-Type" content="text/html; charset=gbk">
<meta http-equiv="expires" content="0">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Cache-Control" content="no-cache">
<meta http-equiv="x-ua-compatible" content="ie=7" />
<style type="text/css" media="screen">
	@import url(../../images/admincp/admin_style.css);
</style>
<script src="../../js/desktop/Compatibility.js">
</script>
<script language="JavaScript">
var agt = navigator.userAgent.toLowerCase();
var is_ie = ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1));
var is_gecko = (navigator.product=='Gecko');
var imgpath = 'images';

//check used
function getObj(id){
	return document.getElementById(id);
}
function showselect(type){
	var selects = get_tags(document,'select');
	for (i=0; i<selects.length; i++) {
		selects[i].style.visibility = type;
	}
}
function checkgroupset(chars){
	if (!confirm("确定删除吗? 如果您删除了此用户组,请到站点缓存数据管理更新用户头衔缓冲!")) return false;
	window.location.href = chars;return false;
}
function get_tags(parentobj,tag){
	if (typeof parentobj.getElementsByTagName!='undefined') {
		return parentobj.getElementsByTagName(tag);
	} else if (parentobj.all && parentobj.all.tags) {
		return parentobj.all.tags(tag);
	} else {
		return null;
	}
}
function ietruebody(){
	return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body;
}
function getTop() {
	return typeof window.pageYOffset != 'undefined' ? window.pageYOffset:ietruebody().scrollTop;
}
function getLeft() {
	return (typeof window.pageXOffset != 'undefined' ? window.pageXOffset:ietruebody().scrollLeft)
}
//other function
function CheckAll(form){
	var ifcheck = null;
	for (var i=0;i<form.elements.length-1;i++){
		var e = form.elements[i];
		if(e.type=='checkbox'){
			if (ifcheck === null) ifcheck = !e.checked;
			e.checked = ifcheck;
			if (typeof e.onclick == 'function') e.onclick();
		}
	}
	return ifcheck;
}
function atccheck(){
	if(document.FORM.atc_title.value==''){
		alert('');
		document.FORM.atc_title.focus();
		return false;
	} else if(document.FORM.fid.value==''){
		alert('');
		document.FORM.fid.focus();
		return false;
	}
	_submit();
}
function level_jump(admin_file){
	var URL=document.mod.selectfid.options[document.mod.selectfid.selectedIndex].value;
	location.href=admin_file+"?adminjob=level&action=editgroup&gid="+URL;
}
function ip_jump(name){
	URL = eval('document.form1.' + name + '.options[document.form1.' + name + '.selectedIndex].value');
	location.href=URL;
}
function pwJsCheck(_this,check,tagName){
	try{
		if (typeof tagName == 'undefined') tagName = "tr";
		if (typeof check == 'undefined') {
			if (typeof _this.checked == 'boolean') {
				check = _this.checked;
			} else {
				check = false;
			}
		}
		var o = _this.parentNode;
		var i = 3;
		while(i--){
			if (o.nodeName.toLowerCase() == tagName) {
				var className =  o.className.replace(/\s?td_bgC/ig, "");
				if (check) {
					className +=' td_bgC';
				}
				o.className = className;
				break;
			} else {
				o = o.parentNode;
			}
		}
	}catch(e){}
}
//Cookies Function
function getCookie(name) {
    var start = document.cookie.indexOf(name + '=');
    var len = start + name.length + 1;
    if ((!start) && (name != document.cookie.substring(0, name.length))) {
        return null;
    }
    if (start==-1) {
        return null;
    }
    var end = document.cookie.indexOf(';', len);
    if (end == -1) {
        end = document.cookie.length;
    }
    return unescape(document.cookie.substring(len,end));
}
function setCookie(name, value, expires, path, domain, secure) {
	if (!expires) {
		expires = new Date();
		expires.setTime(expires.getTime()+31536000);
	}
	document.cookie = name + '=' + escape(value) +
        ( (expires) ? ';expires=' + expires.toGMTString() : '') +
        'path=' + ( (path) ? path : '/') +
        ( (domain)  ? ';domain=' + domain : '') +
        ( (secure)  ? ';secure' : '');
}
function IsElement(id) {
	return document.getElementById(id) != null ? true : false;
}
function elementBind(type,id,stylename,csstext){
	var element = document.createElement(type);
	if (id) {
		element.id = id;
	}
	if (typeof(stylename) == 'string') {
		element.className = stylename;
	}
	if (typeof(csstext) == 'string') {
		element.style.cssText = csstext;
	}
	return element;
}
function addChild(parent,type,id,stylename,csstext){
	parent = objCheck(parent);
	var child = elementBind(type,id,stylename,csstext);
	parent.appendChild(child);
	return child;
}

function delElement(id){
	id = objCheck(id);
	id.parentNode.removeChild(id);
}
function objCheck(obj) {
	if (typeof(obj)=='string') {
		obj	= getObj(obj);
	}
	return obj;
}
document.onkeydown = function(e){
	var e = is_ie ? window.event: e;
	if ( e.keyCode==116) {
		window.location.reload();
		if (is_ie) {
			e.keyCode = 0;
       		e.cancelBubble = true;
		}
		return false;
	}
}
Class = function(aBaseClass, aClassDefine) {
	function class_() {
		this.Inherit = aBaseClass;
		for (var member in aClassDefine) {
			try{this[member] = aClassDefine[member];}catch(e){}		//针对opera,safri浏览器的只读属性的过滤
		}
	}
	class_.prototype = aBaseClass;
	return  new class_();
};
New = function(aClass, aParams) {
	function new_()	{
		this.Inherit = aClass;
		if (aClass.Create) {
			aClass.Create.apply(this, aParams);
		}
	}
	new_.prototype = aClass;
	return  new new_();
};
</script>

<script type="text/javascript">
window.onload = function(){
	if(parent.adminNavClass){
		parent.adminNavClass.initTips();
	}
}
</script>
</head>
<body>
<div class="wrap">

<div class="nav3">
	<ul class="cc">
		<li ><a href="http://localhost/phpwind/admin.php?adminjob=apps&admintype=app_stopic&job=stman">专题管理</a></li>
		<li class="current"><a href="http://localhost/phpwind/admin.php?adminjob=apps&admintype=app_stopic&job=make">制作专题</a></li>
	</ul>
</div><!--
-->
<style type="text/css">
.preview{border:1px dashed #eba90b;background:#fffbf0;width:968px;}
.layoutDraggable {background:#fff; cursor:move;border-top:1px dashed #ffc495;padding-top:5px;margin-bottom:10px;}
.itemDroppable {padding:0 0 5px;background:#ffecdc;border:1px solid #ffc495;margin:5px 0 0;cursor:default;}
.itemDraggable {background:#ffffff;overflow:hidden;border:1px solid #c0dbf8; cursor:default;padding:1px;margin-top:5px;}
.itemDraggable .itemHeader{line-height: 28px;background-color: #e2f0fb;border-bottom:1px solid #c0dbf8;color:#333;padding:0 10px;cursor: move;font-weight: bold;height: 28px;position: relative; font-family:Verdana, Geneva, sans-serif; font-size:14px;margin-bottom:1px;}
.itemDraggable .itemHeader .closeEl{position: absolute;right: 5px;top: 0px;font-weight: normal;font-size: 12px;text-decoration: none;}
.itemDraggable .itemHeader .editEl{position: absolute;right: 28px;top: 0px;font-weight: normal;font-size: 12px;text-decoration: none;}
.widget-top {cursor: move;border:1px solid #adcaea;padding:0 5px;height:18px;line-height:20px;overflow:hidden;float:left;background:#ffffff;margin-right:5px;}
.widget-top:hover{border:1px solid #ff9000;color:#ff5500;}
.widget-top-bg{width:962px;margin:30px auto 5px;}
.sortHelper{border:2px dashed #ffc495;width: auto !important;background:#ffecdc;}
.pwSlide{margin:6px 0;}
.itemContent{padding:4px 10px;}
.itemContent li{line-height:24px;border-bottom:0;}
.itemContent h2{ font-size:14px; font-weight:700; text-align:center;margin:0;margin-top:4px;height:21px;overflow:hidden;line-height:21px;background:none;padding:0;}
.itemContent p{margin:5px 0;text-indent:2em;}
.itemContent tr td,.itemContent tr th{padding:4px 0 10px;}
.itemContent th{vertical-align:top;}
.itemContent th img{margin-top:2px;}
.itemContent td h4{margin-left:10px; font-size:16px;}
.itemContent td p{ text-align:left; text-indent:2em;margin-left:10px;}
.list-img-a{padding-bottom:10px;}
.list-img-a li{float:left;margin:6px 10px 5px 0;display:inline;}
.list-img-a li p{line-height:20px;height:20px;overflow:hidden; text-align:center; text-indent:0;}
.list-img-dl{padding:4px 0;}
.list-img-dl dl{margin:4px 10px 0 0;}
.list-img-dl dd{padding-top:5px;}
.layoutDragElement {cursor:move;border:1px solid #fff;}
.layoutDragElement:hover{border:1px solid #ff5500;}
.topics_tips{border:1px solid #ccc;background:#fff;width:968px;}
.topics_tips_closeB{width:100px;margin:10px auto -1px;border:1px solid #ccc;border-bottom:none;background:#f7f7f7;cursor:pointer;line-height:18px; text-align:center;}
.banner{ position:relative;border:0;padding:0;margin:0;}
.banner h1{ position:absolute;}
.zt_nav li{float:left;line-height:35px; font-size:14px;margin:0 10px; white-space:nowrap;}
.pwSlide {background: #fff;position: relative;width: 100%;height: 240px;overflow: hidden;text-align: left;}
.pwSlide a:hover {text-decoration: none;}
.pwSlide .bg {position: absolute;left: 0;bottom: 0;width: 100%;height: 40px;background: #333333;filter: alpha(opacity = 39);-moz-opacity: 0.39;opacity: 0.39;}
.pwSlide h4 {position: absolute;left: 10px;bottom: 15px;_bottom: 1px;width: 95%;height: 20px;line-height: 16px;z-index: 2;color: #fff;}
.pwSlide ul {margin: 0;padding: 0;position: absolute;right: 5px;bottom: 5px;_bottom: 2px;z-index: 2;}
.pwSlide ul li {list-style: none;float: left;width: 18px;height: 13px;line-height: 15px;text-align: center;margin-left: 1px;}
.pwSlide ul li a {display: block;width: 18px;height: 13px;line-height: 13px;font-size: 10px;font-family: Tahoma;color: #000;background: #f7f7f7;}
.pwSlide ul li a:hover,.pwSlide ul li a.sel {color: #fff;text-decoration: none;background: #ff6600;color: #fff;}
</style>
<form id="opMakeForm" action="http://localhost/phpwind/admin.php?adminjob=apps&admintype=app_stopic&verify=b51b0631&" method="post" enctype="multipart/form-data" onsubmit="return checkSubmit();">
<h2 class="h1" style="margin-top:10px;">专题制作</h2>
<div class="admin_table mb10">
	<table width="100%">
    	<tr class="tr1">
        	<td class="td1">分类</td>
            <td class="td2">
				<select name="category_id" id="category" class="select_wa">

					<option value="1" selected="selected">房产</option>

					<option value="2" >汽车</option>

					<option value="3" >婚庆</option>

					<option value="4" >母婴</option>

					<option value="5" >团购</option>

				</select>
                <span id="opCreateCategory">
                    <span id="opCreateCategoryShowLink">&nbsp;<a id="opCreateCategoryLink" href="javascript:void(0);">创建新分类</a></span>
                    <span id="opCreateCategoryShowForm" style="display:none;">
                        <input id="opCreateCategoryFormInput" type="text" class="input input_wa" name="new_category_name" onkeydown="return checkForCategorySubmit(event);">
                        <span class="btn2"><span><button type="button" id="opCreateCategoryFormSubmit" onfocus="blur();">创 建</button></span></span>
						<span class="bt2"><span><button type="button" id="opHideCategoryForm" onfocus="blur();">取 消</button></span></span>
                        <span id="opCategoryNameError" style="display:none;"><font id="opCategoryNameErrorMsg" color="red">请填写分类名称</font></span>
                    </span>
                </span>
            </td>
        </tr>
		<tr class="tr1">
			<td class="td1">自定义地址 </td>
			<td class="td2">
				http://localhost/phpwind/htm_data/stopic/<input id="stopicFilename" name="file_name" type="text" class="input" value="2" />.html
				（文件夹路径可以在<a id="opJumpToDirSetting" href="javascript:void(0);">动态目录</a>中修改）
			</td>
		</tr>
        <tr class="tr1">
        	<td class="td1">标题</td>
            <td class="td2"><input id="stopicId" type="hidden" name="stopic_id" value="2" /><input id="stopicTitle" name="stopic_title" maxlength="50" type="text" value="（未命名）" class="input input_wa mr10" onblur="ctrlStopicTitle(false);" onfocus="ctrlStopicTitle(true);" />&nbsp;<span class="mr20">限50字节</span>
            	<span class="bt2"><span><button type="button" onfocus="blur();" id="opAdvanceDisplayButton">更多细节设置▼</button></span></span>
        </td>
        </tr>
        <tr class="tr1" id="opShowAdvanceField" style="display:none;">
        	<td class="td2" colspan="2" style="padding:0;border:2px solid #adcaea;padding:0px;"><iframe id="advanceIframe" name="advanceIframe" src="advance.php" width="100%" height="910" frameborder="0" border="0" marginwidth="0" marginheight="0" scrolling="no" allowtransparency="yes"></iframe>
           	  <input type="hidden" id="opShowIframeSaveOk" value="0">
            </td>
        </tr>
    </table>
</div>
<div style="height:75px">
<div id="zt_topbar" class="zt_style mb10">
	<div class="zt_stylebg" style="-moz-user-select:-moz-none;">
    <table width="100%">
        <tr>
            <td class="b">布局</td>
            <td><div class="cc mb10">

			<div class="layoutDragElement" id="type1v0" style="background:url(http://localhost/phpwind/apps/stopic/data/layout/type1v0/logo.png) no-repeat;" title="直列"></div><font id="type1v0_title" style="display:none;">直列</font>

			<div class="layoutDragElement" id="type1v1" style="background:url(http://localhost/phpwind/apps/stopic/data/layout/type1v1/logo.png) no-repeat;" title="1:1"></div><font id="type1v1_title" style="display:none;">1:1</font>

			<div class="layoutDragElement" id="type1v2" style="background:url(http://localhost/phpwind/apps/stopic/data/layout/type1v2/logo.png) no-repeat;" title="1:2"></div><font id="type1v2_title" style="display:none;">1:2</font>

			<div class="layoutDragElement" id="type2v1" style="background:url(http://localhost/phpwind/apps/stopic/data/layout/type2v1/logo.png) no-repeat;" title="2:1"></div><font id="type2v1_title" style="display:none;">2:1</font>

			<div class="layoutDragElement" id="type1v1v1" style="background:url(http://localhost/phpwind/apps/stopic/data/layout/type1v1v1/logo.png) no-repeat;" title="1:1:1"></div><font id="type1v1v1_title" style="display:none;">1:1:1</font>
</div>
            </td>
        </tr>
        <tr>
            <td class="b">模块</td>
            <td>

        <div id="block_banner" class="widget-top">头部横幅</div>

        <div id="block_nvgt" class="widget-top">导航</div>

        <div id="block_thrd" class="widget-top">帖子列表</div>

        <div id="block_thrdSmry" class="widget-top">帖子摘要</div>

        <div id="block_pic" class="widget-top">图片</div>

        <div id="block_picTtl" class="widget-top">图片及标题</div>

        <div id="block_picArtcl" class="widget-top">图文混排</div>

        <div id="block_picPlyr" class="widget-top">图片播放器</div>

        <div id="block_spclTpc" class="widget-top">交互主题</div>

        <div id="block_html" class="widget-top">自定义代码</div>

            </td>
        </tr>
    </table>
    </div>
</div>
</div>
<table width="100%">
	<tr>
		<td>
			<div class="preview cc mb10">
            	<table width="100%">
                <tr><td height="600" valign="top";>
				<div id="container" class="layoutDroppable cc"style="padding:9px;">

<div id="type1v0_1" class="layoutDraggable cc" width="100%"><div class="layoutHeader">
<span>直列</span>
<a class="closeEl" href="javascript:void(0);">[x]</a>
</div><div id="type1v0_1_main" class="itemDroppable" style="width:100%;">&nbsp;<div class="itemDraggable" id="block_banner_101" style="padding:0;margin:0;border:0;"><div class="itemHeader"><span></span><a href="javascript:void(0);" class="editEl">编辑</a><a href="javascript:void(0);" class="closeEl">[x]</a></div><div class="itemContent" style="padding:0;margin:0;border:0;"><!--
-->
<div class="banner">
	<img src="http://localhost/phpwind/apps/stopic/data/style/baby_org/banner.jpg" />

	<h1 style="left:50px;top:50px; font:50px Arial; color:#000000;">我的专题</h1>

</div>

</div></div><div class="itemDraggable" id="block_nvgt_101" style="padding:0;margin:0;border:0;"><div class="itemHeader"><span></span><a href="javascript:void(0);" class="editEl">编辑</a><a href="javascript:void(0);" class="closeEl">[x]</a></div><div class="itemContent" style="padding:0;margin:0;border:0;"><!--
-->


<ul class="zt_nav cc" style="background-color:#e1a521;">

	<li><a style="color:#ffffff;" href="javascript:;">导航链接1</a></li>

	<li><a style="color:#ffffff;" href="javascript:;">导航链接2</a></li>

	<li><a style="color:#ffffff;" href="javascript:;">导航链接3</a></li>

</ul>


</div></div></div></div>


				</div>
                </td></tr>
                </table>
			</div>
		</td>
	</tr>

	<tr>
		<td>

		</td>
	</tr>
</table>
<div class="mb10">
	<span class="btn"><span><button type="button" onclick="createStopic(false);">生成专题</button></span></span>
    <span class="bt"><span><button type="button" onclick="previewStopic();return false;">预 览</button></span></span>
</div>
</form>

<script language="JavaScript" src="js/global.js"></script>
<script language="JavaScript" src="js/core.js"></script>
<script language="JavaScript" src="js/pw_ajax.js"></script>
<script language="JavaScript" src="js/color_picker.js"></script>
<script language="javascript" src="js/getelementpos.js"></script>
<script language="javascript" src="js/drag.js"></script>
<script language="javascript" src="js/selectstyle.js"></script>
<script language="javascript">

var AJAXURL = 'http://localhost/phpwind/admin.php?adminjob=apps&admintype=app_stopic&verify=b51b0631';
var STOPIC_ID = 0;

var dragLayoutImpl = New(externalLayoutDrag,['layoutDroppable','layoutDraggable','layoutHeader','editEl','closeEl','itemContent','preview', ['layoutDraggable', 'itemDraggable']]);
dragLayoutImpl.externalLayoutDrag('layoutDragElement');

var dragItemImpl = New(externalDrag,['itemDroppable','itemDraggable','itemHeader','editEl','closeEl','itemContent','container', ['layoutDraggable', 'itemDraggable']]);
dragItemImpl.externalDrag('widget-top');

function createStopic(isCover) {
	var block_config = dragLayoutImpl.getStopicConfig() + dragItemImpl.getStopicConfig();
	if (!isStopicInit()) return false;
	var stopic_id = '&stopic_id=' + isStopicInit();
	var category_id = '&category_id=' + getObj('category').value;
	var stopic_title = '&stopic_title=' + getObj('stopicTitle').value;
	var file_name = '&file_name=' + getObj('stopicFilename').value;
	var is_cover = '&is_cover=' + (isCover ? 1 : 0);
	ajax.send(AJAXURL,'job=creatstopic' + stopic_id + category_id + stopic_title + block_config + file_name + is_cover, ajax.get);
}
function previewStopic() {
	var block_config = dragLayoutImpl.getStopicConfig() + dragItemImpl.getStopicConfig();
	if (!isStopicInit()) return false;
	var stopic_id = '&stopic_id=' + isStopicInit();
	url = 'http://localhost/phpwind/admin.php?adminjob=apps&admintype=app_stopic&job=preview' + stopic_id + block_config;
	window.open(url,'_blank');
}

function checkSubmit() {
	
}


function getRadioValue(radioName){
	var obj;
	obj=document.getElementsByName(radioName);
	if(obj!=null){
		var i;
		for(i=0;i<obj.length;i++){
			if(obj[i].checked){
				return obj[i].value;
			}
		}
	}
	return null;
}


window.onload = function() {
	initStopic();
};

//create stopic
function isStopicInit() {
	return getObj('stopicId').value * 1;
}

function initStopic() {
	if (isStopicInit()) {
		return true;
	}

	var defaultStopicTitle = '（未命名）';
	var defaultStopicCategory = getObj('category').value;
	createNewStopic(defaultStopicTitle, defaultStopicCategory);
}

function ctrlStopicTitle(isFocus) {
	var defaultStopicTitle = '（未命名）';
	var title = getObj('stopicTitle').value;
	if (isFocus) {
		if (title == defaultStopicTitle) {getObj('stopicTitle').value = '';}
		document.body.onselectstart = function(){return true;}
	} else {
		if ('' == title) {getObj('stopicTitle').value = defaultStopicTitle;}
		document.body.onselectstart = function(){return false;}
	}
}


function createNewStopic(stopicTitle, stopicCategory) {
	ajax.send("http://localhost/phpwind/admin.php?adminjob=apps&admintype=app_stopic&verify=b51b0631", "job=initstopic&category="+stopicCategory+"&title="+stopicTitle, function(){
		var isSuccess = ajax.request.responseText;
		isSuccess = isSuccess.split('	');
		if ('success' != isSuccess[0]) {
			alert('初始化专题失败');
			//self.location = '/phpwind/admin.php?adminjob=apps&admintype=app_stopic';
		} else {
			getObj('stopicTitle').value = stopicTitle;
			getObj('stopicId').value = isSuccess[1];
		}
	});
	return true;
}


getObj("opAdvanceDisplayButton").onclick = function() {
	var isHidden = getObj("opShowAdvanceField").style.display == 'none';
	getObj("opShowAdvanceField").style.display = isHidden ? '' : 'none';
	getObj('opAdvanceDisplayButton').innerHTML = isHidden ? '收起细节设置▲' : '更多细节设置▼';
	zt_topbar.reloadOrigin();
	
}
//getObj("opTipOpen").onclick = tipDisplayCtrl;
//getObj("opTipClose").onclick = tipDisplayCtrl;

//category
getObj("category").onchange = function() {
	getObj("advanceIframe").src = getObj("opMakeForm").action + "&job=advance&stopic_id=" + isStopicInit() + "&category_id=" + getObj("category").value;
}

//create category
getObj("opCreateCategoryLink").onclick = function() {
	getObj("opCreateCategoryShowForm").style.display = '';
	getObj("opCreateCategoryLink").style.display = 'none';
	getObj("opCreateCategoryFormInput").value = '';
	getObj("opCreateCategoryFormInput").focus();
}
getObj("opHideCategoryForm").onclick = function() {
	getObj("opCreateCategoryShowForm").style.display = 'none';
	getObj("opCreateCategoryLink").style.display = '';
}
getObj("opCreateCategoryFormSubmit").onclick = function() {
	if (!checkCategoryName()) {
		getObj("opCreateCategoryFormInput").focus();
		return false;
	}
	createCategory();
}
function checkForCategorySubmit(event) {
	if (event.keyCode == 13) {
		getObj("opCreateCategoryFormSubmit").onclick();
		event.cancel = true;
		return false;
	}
	return true;
}
function checkCategoryName() {
	var categoryName = getObj("opCreateCategoryFormInput").value;
	if ("" == categoryName) {
		ctrlErrorMsg(true, 'opCategoryNameError', '请填写分类名称', 'opCategoryNameErrorMsg');
	} else {
		ctrlErrorMsg(false, 'opCategoryNameError', '');
		return true;
	}
	return false;
}
function createCategory() {
	ajax.send("http://localhost/phpwind/admin.php?adminjob=apps&admintype=app_stopic&verify=b51b0631", "job=createcategory&name="+getObj("opCreateCategoryFormInput").value, function(){
		var isSuccess = ajax.request.responseText;
		isSuccess = isSuccess.split('	');
		if ('success' != isSuccess[0]) {
			ctrlErrorMsg(true, 'opCategoryNameError', '分类名有重复', 'opCategoryNameErrorMsg');
			getObj("opCreateCategoryFormInput").focus();
		} else {
			ctrlErrorMsg(false, 'opCategoryNameError', '');
			getObj("category").options.add(new Option(getObj("opCreateCategoryFormInput").value, isSuccess[1]));
			getObj("category").value = isSuccess[1];
			getObj("opCreateCategoryShowForm").style.display = 'none';
			getObj("opCreateCategoryLink").style.display = '';
			getObj("category").onchange();
		}
	});
	return true;
}
function ctrlErrorMsg(isDisplay, displayId, msg, msgId) {
	if ('' != msg) {
		getObj(msgId).innerHTML = msg;
	}
	getObj(displayId).style.display = isDisplay ? '' : 'none';
}

getObj("opJumpToDirSetting").onclick = function() {
	if (parent != undefined && parent.PW != undefined) {
		parent.PW.Dialog({id:'safe',url:'http://localhost/phpwind/admin.php?adminjob=settings&admintype=safe',name:'安全与优化'});
	}
	return false;
}

//pickcolor
function pickReback(obj,color){
	if (typeof obj == 'string') {
		obj = getObj(obj);
	}
	obj.style.color = color;
}
</script>
<script src="apps/stopic/js/topbar.js"></script>


<div class="c"></div>
</div>

<script type="text/javascript" src="js/desktop/plugin.js"></script>
<script type="text/javascript">
//设置所有的radio
var allInputs = document.getElementsByTagName('input');
if(allInputs && allInputs.length>0){
	for(var i=0; i<allInputs.length;i++)
	{
		var p = allInputs[i].parentNode;
		if(p.tagName=='LI'&& allInputs[i].type=='radio')
		{
			allInputs[i].checked && (p.className='current');
			p.onclick = function(){radioWithWords(this)};
		}
	}
}
</script>
</body></html>

<script language="JavaScript" src="http://nt.phpwind.net/notice.php?bbsname=PHPWind&totalmember=&threads=&posts=&hits=&yposts=&version=7.5 SP3&repair=20100303&charset=gbk&c=0&u=&sysversion=&dbversion=&url=localhost&ystat=1&hash=81e63c66838098dcf56fadb551297ff5&from="></script>
